package com.bugbuff.dubbo.server.controller;


import com.bugbuff.common.pojo.PageResult;
import com.bugbuff.dubbo.server.service.CommentInfoService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("management/manage/messages")
public class CommentInfoController {
    @Autowired
    private CommentInfoService commentInfoService;
    @GetMapping("comments")
    public PageResult queryCommentList(@RequestParam(value = "pagesize",defaultValue = "10") Integer pagesize, @RequestParam(value = "page",defaultValue = "1") Integer page, String sortProp , String sortOrder, String messageID){
        return this.commentInfoService.queryCommentList(pagesize,page,sortProp ,sortOrder,messageID);
    }
}
